// import './polyfill';
import dva from 'dva';
import './utils/store'
import createLoading from 'dva-loading';
import 'moment/locale/zh-cn';
// import './rollbar';
import {ModalView} from 'antd-extra';
import './index.less';

// 1. Initialize
const app = dva({
  // history: createHistory(),
});

//setAuthority('guest');

// 2. Plugins
app.use(createLoading());

// 3. Register global model
app.model(require('./models/user').default);

// 4. Router
app.router(require('./router').default);

// 5. Start
app.start('#root');

ModalView.bindApp(app);
export default app._store; // eslint-disable-line
